Graphics subsystem rendering 3D graphics typically include a Z-buffer used to determine the depth of an image for rendering purposes. For an LCD (Liquid Crystal Display) or similar display device with 1024×768 cells and 16 bits of Z-buffer data per cell, a 1.5MB buffer may be required. It is common to initialize each entry in the Z-buffer, or a well-defined subset of the entries in the Z-buffer based on a background value (usually set to a number representing indefinitely far way, or the maximum number). Executing a write to each individual data location can be a slow, inefficient process. Furthermore, once a Z-buffer is initialized, painting objects includes determining whether the object is in the foreground or the background relative to an image already painted. This determination includes reading the current Z-value and comparing that to a potential new Z-value, and then either allowing the write to occur or canceling it as appropriate based on whether the data to be written is in the foreground or the background.
Thus, it would be advantageous to provide a method of quickly initializing and quickly reading values of a Z-buffer.